package com.ruoyi.system.domain.dto;

import java.util.ArrayList;
import java.util.List;

/**
 * 字典导入结果数据传输对象
 * 
 * @author ruoyi
 */
public class DictImportResultDTO
{
    /** 是否成功 */
    private boolean success;

    /** 成功导入的字典类型数量 */
    private int successTypeCount;

    /** 成功导入的字典数据数量 */
    private int successDataCount;

    /** 失败的字典类型数量 */
    private int failTypeCount;

    /** 失败的字典数据数量 */
    private int failDataCount;

    /** 错误信息列表 */
    private List<String> errorMessages;

    /** 成功信息列表 */
    private List<String> successMessages;

    public DictImportResultDTO()
    {
        this.errorMessages = new ArrayList<>();
        this.successMessages = new ArrayList<>();
    }

    public boolean isSuccess()
    {
        return success;
    }

    public void setSuccess(boolean success)
    {
        this.success = success;
    }

    public int getSuccessTypeCount()
    {
        return successTypeCount;
    }

    public void setSuccessTypeCount(int successTypeCount)
    {
        this.successTypeCount = successTypeCount;
    }

    public int getSuccessDataCount()
    {
        return successDataCount;
    }

    public void setSuccessDataCount(int successDataCount)
    {
        this.successDataCount = successDataCount;
    }

    public int getFailTypeCount()
    {
        return failTypeCount;
    }

    public void setFailTypeCount(int failTypeCount)
    {
        this.failTypeCount = failTypeCount;
    }

    public int getFailDataCount()
    {
        return failDataCount;
    }

    public void setFailDataCount(int failDataCount)
    {
        this.failDataCount = failDataCount;
    }

    public List<String> getErrorMessages()
    {
        return errorMessages;
    }

    public void setErrorMessages(List<String> errorMessages)
    {
        this.errorMessages = errorMessages;
    }

    public List<String> getSuccessMessages()
    {
        return successMessages;
    }

    public void setSuccessMessages(List<String> successMessages)
    {
        this.successMessages = successMessages;
    }

    public void addErrorMessage(String message)
    {
        this.errorMessages.add(message);
    }

    public void addSuccessMessage(String message)
    {
        this.successMessages.add(message);
    }

    @Override
    public String toString()
    {
        return "DictImportResultDTO{" +
                "success=" + success +
                ", successTypeCount=" + successTypeCount +
                ", successDataCount=" + successDataCount +
                ", failTypeCount=" + failTypeCount +
                ", failDataCount=" + failDataCount +
                ", errorMessages=" + errorMessages +
                ", successMessages=" + successMessages +
                '}';
    }
}
